<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/>
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <link rel="stylesheet" href="../aui/css/aui.2.0.css">
</head>
    <body>
        <div id="app">
            <div class="aui-content aui-margin-b-15">
                <ul class="aui-list aui-form-list">
                    <li class="aui-list-header">带有输入框</li>
                    <li class="aui-list-item">
                        <div class="aui-list-item-inner">
                            <div class="aui-list-item-label">
                                username
                            </div>
                            <div class="aui-list-item-input">
                                <input type="text" name="username" placeholder="username" v-model="username">
                            </div>
                        </div>
                    </li>
                    <li class="aui-list-item">
                        <div class="aui-list-item-inner">
                            <div class="aui-list-item-label">
                                Password
                            </div>
                            <div class="aui-list-item-input">
                                <input type="password" placeholder="Password">
                            </div>
                        </div>
                    </li>
                    <li class="aui-list-item">
                        <div class="aui-list-item-inner">
                            <div class="aui-list-item-label">
                                age
                            </div>
                            <div class="aui-list-item-input">
                                <input type="number" name="age" placeholder="Number" v-model.number="age">
                            </div>

                        </div>
                    </li>
                    <li class="aui-list-item">
                        <div class="aui-list-item-inner">

                            <div class="aui-list-item-label">
                                留言：
                            </div>
                            <div class="aui-list-item-input">
                                <input type="text" placeholder="Number" v-model.trim="content">
                            </div>
                        </div>
                    </li>
                </ul>
            </div>
        </div>
    </body>
</html>
<script src="vue2.1.js"></script>
<script>
    var vm = new Vue({
        el: '#app',
        data: {
            username:'',
            password:'',
            age: 0,
            content: '孟老师vue高级教程'
        },
        methods: {
            addTodo: function () {
                var text = this.newTodo.trim()
                if (text) {
                    this.todos.push({ text: text })
                    this.newTodo = ''
                }
            },
            removeTodo: function (index) {
                this.todos.splice(index, 1)
            }
        },
    	watch: {
    		c: {
    		  handler: function (val, oldVal) {

    		  },
    		  deep: true
    		}
    	}
    });
</script>
